<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>聊天demo</title>
		<script type="text/javascript" src="js/jquery.min.js" ></script>
		<script src="js/utils.js" type="text/javascript" charset="utf-8"></script>
		<script src="js/chat.js" type="text/javascript" charset="utf-8"></script>
		<link rel="stylesheet" type="text/css" href="css/chat.css"/>
		
		<script>
			$(function(){
				//初始化socket
				initWebSocket();
			});
			
		</script>
	</head>
	<body>
		<div id="headDiv">
			<input type="text" id="userName" />
			<button onclick="setUserId(userName.value)">设置名称并登陆</button>
			<br />
		</div>
		<div id="onlineUserDiv">
			当前在线人数：<span id="OnlineNum">0</span><br />
			在线用户：
			<div id="onlineUsers"></div>
			
		</div>
		<div id="chatDiv">
			<!--显示消息-->
			<div id="textAreaID">
				<span>事件面板：</span>
			</div>
			<div id="publicChatDiv">
				<span>公共频道：</span>
				<div id="publicMsgDiv">
				</div>
				<div id="PublicMsgInputDiv">
					消息：<input id="chatMsgInput" />
					<button onclick="sendAll(chatMsgInput.value)">发送</button>
				</div>
			</div>
		</div>
		
	</body>
</html>
